package com.three.controller;

import com.three.aop.LogAnotation;
import com.three.utils.OssUtils;
import com.three.vo.R;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.multipart.MultipartFile;

@RestController
public class UploadController {
    //文件上传
    @PostMapping("/upload")
    @LogAnotation("文件上传")//日志
    public R upload(MultipartFile file) {
        String sql = OssUtils.ossUpload(file);
        return R.ok(sql);
    }
}
